package cn.com.surker.lab.service;

import cn.com.surker.lab.entity.LabExpend;
import cn.com.surker.lab.vo.LabExpendVo;
import com.baomidou.mybatisplus.extension.service.IService;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 工控机消耗表 服务类
 * </p>
 *
 * @author admin
 * @since 2024-11-05
 */
public interface LabExpendService extends IService<LabExpend> {


	/**
	 * 料仓消耗统计
	 * @param orgId
	 * @param lineId 生产线ID
	 * @param storageId 仓位ID
	 * @param materialId 材料ID
	 * @param startTime
	 * @param endTime
	 * @return
	 */
	List<LabExpendVo> findStorageExpend(Long orgId, Long lineId, Long storageId, Long materialId, String startTime,
										String endTime, Integer type, Integer materialType, Integer breedType);

	/**
	 * 导出料仓消耗报表
	 * @param sheetName
	 * @param title
	 * @param expendList
	 * @return
	 */
	XSSFWorkbook exportStorageExpend(String sheetName, String title, List<LabExpendVo> expendList, Integer type);

	/**
	 * 导出料仓消耗报表
	 * @param sheetName
	 * @param title
	 * @param expendList
	 * @return
	 */
	XSSFWorkbook exportDosageExpend(String sheetName, String title, List<Map<String, Object>> expendList);
	/**
	 * 按强度查询原材平均消耗
	 * @param searchVal
	 * @param startTime
	 * @param endTime
	 * @return
	 */
	List<Map<String, Object>> findStrengthDosage(String dbCode, String searchVal, Long indentId, Long lineId, String startTime, String endTime);
}
